<div id="header">
    <div class="header-content">
      <div class="search pull-right">
        <div class="tools pull-right"></div>
        <div class="nav_login" id="iCMS-nav-login">
          <a href="<!--{iCMS:router url='/api/user/login'}-->" class="iCMS_user_login" title="登录"><i class="fa fa-user"></i> 登录</a>
          <a href="<!--{iCMS:router url='/api/user/register'}-->" target="_blank"><i class="fa fa-heart"></i> 注册</a>
        </div>
        <div class="nav_profile" id="iCMS-nav-profile">
          <!--{include file="iCMS://user/menu.htm"}-->
          <span><a href="<!--{iCMS:router url='/user/publish'}-->" target="_blank"><i class="fa fa-edit"></i> 发表文章</a></span>
        </div>
        <div class="clearfix mb5"></div>
        <form id="iCMS-search-box" class="form-inline" action="<!--{iCMS:router url='/api'}-->" method="get" target="_blank">
          <div class="input-append">
            <input name="app" type="hidden" value="search" />
            <input type="text" name="q" class="span4" placeholder="请输入关键词" value="<!--{$search.title}-->">
            <button type="submit" class="btn iCMS_search_btn" ><i class="fa fa-search"></i> 搜索</button>
          </div>
        </form>
      </div>
      <div class="logo"></div>
    </div>
    <div class="navbar navbar-static-top">
      <div class="navbar-inner">
        <div class="nav-collapse collapse header-content">
          <ul class="nav">
            <li class="active" id="c0"><a href="<!--{$site.url}-->">首页</a></li>
            <li class="divider-vertical"></li>
            <!--{iCMS:category:list loop="true" stype='top' row="10"}-->
            <!--{if $category_list.child}-->
            <li class="dropdown"  id="c<!--{$category_list.cid}-->"><a class="dropdown-toggle" data-toggle="dropdown" href="<!--{$category_list.url}-->" target="_blank"><span><!--{$category_list.name}--></span><b class="caret"></b></a>
              <ul class="dropdown-menu">
                <li><!--{iCMS:category:list as="sub_category" loop="true" stype='sub' row="10" cid=$category_list.cid}-->
                  <a href="<!--{$sub_category.url}-->" target="_blank"> <i class="fa fa-star-o"></i> <!--{$sub_category.name}--></a>
                  <!--{/iCMS}--></li>
              </ul>
              <!--{else}-->
            <li id="c<!--{$category_list.cid}-->"><a href="<!--{$category_list.url}-->" target="_blank"><span><!--{$category_list.name}--></span></a>
              <!--{/if}-->
            </li>
            <li class="divider-vertical"></li>
            <!--{/iCMS}-->
          </ul>
        </div>
      </div>
    </div>
  </div>
  <script type="text/javascript">
$("#c0").removeClass("active");
$("#c<!--{$category.cid|default:0}-->").addClass("active");
</script>

